import request from '@/utils/request'
export default {

  // 根据视频id删除阿里云视频
  deleteAliyunVideoById(VideoId) {
    return request({
      url: 'http://localhost:8003/eduvod/video/removeAliyunVideoById/' + VideoId,
      method: 'delete'
    })
  },

  // 添加小节
  addVideo(video) {
    return request({
      url: `/eduservice/video/addVideo`,
      method: `post`,
      data: video
    })
  },
  // 根据id查询小节
  getVideoById(videoId) {
    return request({
      url: `/eduservice/video/getVideoById/${videoId}`,
      method: `get`
    })
  },
  // 修改小节
  updateVideo(video) {
    return request({
      url: `/eduservice/video/updateVideo`,
      method: `post`,
      data: video
    })
  },
  // 删除小节
  deleteVideo(id) {
    return request({
      url: `/eduservice/video/deleteVideo/${id}`,
      method: `delete`
    })
  },
  // 课程确认信息显示
  getPublishCourseInfo(courseId) {
    return request({
      url: '/eduservice/course/getpublishCourseInfo/' + courseId,
      method: 'get'
    })
  }
}
